package cn.sofwin.day0327.test02;

public class Main {
    public static void main(String[] args) {
        Thread t1 = new Thread(new MyTask());
        Thread t2 = new Thread(new MyTask());
        Thread t3 = new Thread(new Run());

        t1.start();
        t2.start();
        t3.start();
    }

    static class MyTask implements Runnable{
        @Override
        public void run() {
            for (int i = 0; i < 20; i++) {
                System.out.println(i+1 + "你好" + Thread.currentThread().getName());
            }
        }
    }
}
